package Test;

import lejos.nxt.Button;
import lejos.nxt.LCD;
import lejos.nxt.SensorPort;

public class EleMagnetTest {

	public static void main(String[] args) {
		while(true) {
			SensorPort.S4.setMode(2);
			while(true) {
				System.out.println("Press Enter = NO");
				Button.ENTER.waitForPress();
				LCD.clear();
				SensorPort.S4.setSensorPin(0, 1);
				System.out.println("Press Enter = OFF");
				Button.ENTER.waitForPress();
				LCD.clear();
				SensorPort.S4.setSensorPin(0, 0);
			}
		}
	}

}
